//
//  XSQMineTableViewController.swift
//  WeiBo
//
//  Created by 许世强 on 2017/3/26.
//  Copyright © 2017年 许世强. All rights reserved.
//

import UIKit

class XSQMineTableViewController: XSQVistorTableViewController {

    override func viewDidLoad() {
        super.viewDidLoad()

        if isLogin{
            //登录的状态
            setupPushBtn()
        } else {
        
            visitorView?.updataVisitorInfo(imageName: "visitordiscover_image_profile", message: "登录后，你的微博、相册、个人资料会显示在这里，展示给别人")
        }
    
        
    }
    
    //创建右上角push按钮
    private func setupPushBtn(){
    
         navigationItem.rightBarButtonItem = UIBarButtonItem(title: "push",target:self,action:#selector(pushBtnAction))
    }
    
    //点击按钮触发push事件
    @objc private func pushBtnAction(){
    
        let testVc = XSQTestViewController()
        
        self.navigationController?.pushViewController(testVc, animated: true)
    }
    
}
